import request from '@/utils/request.js'

// 获取任务详情模板
export function getPatrolTaskTemplate(data) {
  return request({
    url: '/author/applet/appletAuthorRest/getPatrolTaskTemplate',
    method: 'GET',
    data: data
  })
}

// 获取任务详情
export function getPatrolTaskPlanOne(data) {
  return request({
    url: '/author/applet/appletAuthorRest/getPatrolTaskPlanOne',
    method: 'GET',
    data: data
  })
}

// 任务提交
export function putPatrolTaskPlan(data, query) {
  return request({
    url: `/author/applet/appletAuthorRest/putPatrolTaskPlan?${query}`,
    method: 'POST',
    header: {'contentType': 'application/json'},
    data: data
  })
}

// 案件上报
export function createWorkOrderFXObjFromXF(data) {
  return request({
    url: `/author/patrolTask/appPatrolTaskTranWorkAnonRest/createWorkOrderFXObjFromXF`,
    method: 'POST',
    header: {'contentType': 'application/json'},
    data: data
  })
}
